﻿<%@ Page Theme="BlueSkin" Title="Lms System : Log in" Language="C#" AutoEventWireup="true" CodeFile="LoginEN.aspx.cs" Inherits="LoginEN" MasterPageFile="~/LmsWebSite/MasterEN.master" %>


 
 
    <asp:Content ID="Content1" ContentPlaceHolderID="head" Runat="Server">
    
    <script type="text/javascript">


        function trimLeft(strIn) {
            try {
                while (strIn.length > 0) {
                    if (strIn.charAt(0) == ' ') {
                        if (strIn.length > 1) {
                            strIn = strIn.substring(1, strIn.length);

                        }
                        else
                            return '';
                    }
                    else
                        return strIn;
                }
            }
            catch (e) {
                return strIn;
            }

            return strIn;
            
        }

        function trimRight(strIn) {

            try {
                while (strIn.length > 0) {
                    if (strIn.charAt(strIn.length - 1) == ' ') {
                        if (strIn.length > 1) {
                            strIn = strIn.substring(0, strIn.length - 1);

                        }
                        else
                            return '';
                    }
                    else
                        return strIn;
                }
            }
            catch (e) {
                return strIn;
            }

            return strIn;
        }
        
        
        
        function validateUser(source, args) {
            var txtBadge = document.getElementById('');
            var txtID = document.getElementById('');

            var varStr1 = trimLeft(trimRight(txtBadge.value));
            var varStr2 = trimLeft(trimRight(txtID.value));

            if (varStr1 == '' && varStr2 == '') {
                args.IsValid = false;
                return;
            }

            if (varStr1 != '' && varStr2 != '') {
                args.IsValid = false;
                return;
            }

            args.IsValid = true;


        }
        
        
    </script>

    </asp:Content>
<asp:Content ID="Content2" ContentPlaceHolderID="ContentPlaceHolder1" Runat="Server">

    <div style="margin-left: auto; margin-right: auto; " class="allWidth">
        <table cellspacing="0" cellpadding="0"  style="background-color: #ffffff" class="allWidth">
           
            <tr>
                <td style="padding-top: 20px">
                   
                   
                   <!-- Page Content -->
                   
                   
                   
                      <div class="allWidth" style="text-align:center;font-size:14px;" >
        <div style="margin-left:auto;margin-right:auto;width:350px;" class="aligning">
            <div class="clearing" style="font-size:1px;height:100px;width:1px;"></div>
            
            <div class="floating" style="width:100px;">Badge# :</div>
            <div class="floating" style="width:200px;">
                <asp:TextBox ID="txtBadge" runat="server" style="width:190px;"></asp:TextBox>
            </div>
            <div class="floating">
                <%--<asp:CustomValidator ID="cv1" runat="server" 
                    ErrorMessage="Please enter at least one number Badge or ID , Don't enter the two fields !" 
                     onservervalidate="cv1_ServerValidate" ClientValidationFunction="validateUser">*</asp:CustomValidator>--%>
                <asp:RequiredFieldValidator ID="rfvBadge" runat="server" ErrorMessage="You must enter your badge first" ControlToValidate="txtBadge">*</asp:RequiredFieldValidator>



            </div>
            <div class="clearing" style="font-size:1px;height:10px;width:1px;"></div>
            
            <%--<div class="floating" style="width:100px;">ID# :</div>
            <div class="floating" style="width:200px;">
                <asp:TextBox ID="txtID" runat="server" style="width:190px;"></asp:TextBox>
            </div>--%>
            <div class="clearing" style="font-size:1px;height:10px;width:1px;"></div>
            
            <div class="floating" style="width:100px;">Password :</div>
            <div class="floating" style="width:200px;">
                <asp:TextBox ID="txtPassword" runat="server" style="width:190px;" 
                    TextMode="Password"></asp:TextBox>
            </div>
            <div class="floating">
                <asp:RequiredFieldValidator ID="rfvPassword" runat="server" ErrorMessage="Please enter a password !" ControlToValidate="txtPassword">*</asp:RequiredFieldValidator>
            </div>
            
            <div class="clearing" style="font-size:1px;height:10px;width:1px;"></div>
            
            <div class="floating" style="width:100px;"></div>
            <div class="floating" style="width:200px;">
                <asp:CheckBox ID="chkRemeber" runat="server" Text="Remeber Me" />
            </div>
            <div class="floating">
                
            </div>

            <div class="clearing" style="font-size:1px;height:10px;width:1px;"></div>

            <div class="floating" style="width:300px;">
                <div style="float:right;">
                    <asp:Button ID="btnLogin" runat="server" Text="Log in" 
                    onclick="btnLogin_Click" BorderStyle="Solid" BorderColor="Orange" 
                        BackColor="DarkOrange" ForeColor="White" />
                </div>
                <div style="font-size:1px;width:10px;height:1px;float:right;"></div>
                 <div style="float:right;padding-top:5px;">
                   <asp:HyperLink ID="hlHelp" runat="server" Text="Help" 
                         NavigateUrl="~/LmsWebSite/SelfServicesEN.aspx" Target="_blank"  
                          style="text-align:center;"></asp:HyperLink>
                </div>


                <div style="font-size:1px;width:10px;height:1px;float:right;"></div>
                 <div style="float:right;padding-top:5px;">
                   <asp:HyperLink ID="hlForget" runat="server" Text="Forget password" 
                         NavigateUrl="~/LmsWebSite/ForgetPasswordEN.aspx" Target="_blank"  
                          style="text-align:center;"></asp:HyperLink>
                </div>


                <div style="font-size:1px;width:10px;height:1px;float:right;"></div>
                 <div style="float:right;padding-top:5px;">
                   <asp:HyperLink ID="hlNewAccount" runat="server" Text="New Account" 
                         NavigateUrl="~/LmsWebSite/RegisterAccountEN.aspx" Target="_blank"  
                          style="text-align:center;"></asp:HyperLink>
                </div>
                
            </div>
            
            <div class="clearing" style="font-size:1px;height:10px;width:1px;"></div>
            
            <div  class="floating aligning direction" style="width:300px;">
                <asp:Label ID="lblError" runat="server" Text="" Width="100%" ForeColor="Red"></asp:Label><br />
                <asp:ValidationSummary ID="vsError" runat="server" />
                    
            </div>
            
            
            <div class="clearing" style="font-size:1px;height:100px;width:1px;"></div>
        </div>
    
    <div class="clearing"></div>
    </div>
                   
                   
                   
                   <!-- end of Page Content -->
                   
                   
                   
                   
                   
                   
                </td>
            </tr>
           
        </table>
        
    </div>




    <div class="clearing" style="height:10px;"></div>
    <div class="direction aligning" 
        style="margin-left:auto;margin-right:auto;width:150px; font-size:12px;">
        Best Viewed At 1152 x 864
    </div>
 
    
    
    
   </asp:Content>
